<?php
// +----------------------------------------------------------------------
// | author: admin
// +----------------------------------------------------------------------

namespace app\adminapi\validate\travel;


use app\common\validate\BaseValidate;


/**
 * LinePrice验证器
 * Class LinePriceValidate
 * @package app\adminapi\validate\travel
 */
class LinePriceValidate extends BaseValidate
{

     /**
      * 设置校验规则
      * @var string[]
      */
    protected $rule = [
        'id' => 'require',
        'line_id' => 'require',
        'price' => 'require',
        'travel_time' => 'require',

    ];


    /**
     * 参数描述
     * @var string[]
     */
    protected $field = [
        'id' => 'id',
        'line_id' => '线路ID',
        'price' => '价格',
        'travel_time' => '出行日期',

    ];


    /**
     * @notes 添加场景
     * @return LinePriceValidate
     * @author admin
     * @date 2025/04/29 09:56
     */
    public function sceneAdd()
    {
        return $this->only(['line_id','price','travel_time']);
    }


    /**
     * @notes 编辑场景
     * @return LinePriceValidate
     * @author admin
     * @date 2025/04/29 09:56
     */
    public function sceneEdit()
    {
        return $this->only(['id','line_id','price','travel_time']);
    }


    /**
     * @notes 删除场景
     * @return LinePriceValidate
     * @author admin
     * @date 2025/04/29 09:56
     */
    public function sceneDelete()
    {
        return $this->only(['id']);
    }


    /**
     * @notes 详情场景
     * @return LinePriceValidate
     * @author admin
     * @date 2025/04/29 09:56
     */
    public function sceneDetail()
    {
        return $this->only(['id']);
    }

    public function sceneStatus()
    {
        return $this->only(['id','status']);
    }

}